cmake_minimum_required(VERSION 3.1 FATAL_ERROR)
project(SHEncoder LANGUAGES CXX CUDA)
set(CMAKE_CXX_STANDARD 17)

find_package(CUDA REQUIRED)
find_package(Torch REQUIRED NO_MODULE PATHS E:/Tools/libtorch NO_DEFAULT_PATH)

set(SRCS shencoder.cuh shencoder.cu)
add_library(SHEncoder SHARED ${SRCS})

target_link_libraries(SHEncoder "${TORCH_LIBRARIES}")